Skip to content

Instantly share code, notes, and snippets.

@antfroger
antfroger / README.md
Last active May 13, 2024 15:30
Using xdebug with Windows 10, WSL2, Docker and VS Code

Configuring xdebug to work with Windows 10 (WSL2), Docker and VS Code

Configuring your dev environment to be able to use xdebug when you're working on Windows 10 (with WSL2) and Docker with VS Code can be (a bit) tricky.
This is a quick reminder of how I've done that.

Configuring the environment

  1. Install and configure xdebug in Docker

Install xdebug according to the Docker image you're using

@schwarzeni
schwarzeni / util.go
Last active May 13, 2024 15:29
[golang] get specific network interface's IPv4 address
package util
import (
"errors"
"fmt"
"net"
)
// useful links:
// https://stackoverflow.com/questions/27410764/dial-with-a-specific-address-interface-golang
@umayr
umayr / recover-deleted-branch.sh
Created April 1, 2016 11:41
How to recover a deleted branch
## Pre-requisite: You have to know your last commit message from your deleted branch.
git reflog
# Search for message in the list
# a901eda HEAD@{18}: commit: <last commit message>
# Now you have two options, either checkout revision or HEAD
git checkout a901eda
# Or
git checkout HEAD@{18}
@Joao-Peterson
Joao-Peterson / gmk67-manual.md
Last active May 13, 2024 15:28
GMK67 manual (English)
@leocomelli
leocomelli / git.md
Last active May 13, 2024 15:27
Lista de comandos úteis do GIT

GIT

Estados

  • Modificado (modified);
  • Preparado (staged/index)
  • Consolidado (comitted);

Ajuda

@justinnoel
justinnoel / README.md
Created November 12, 2022 12:34
Configuring Sessions in Remix for Cloudflare Pages
@ruanbekker
ruanbekker / tree_style_tab_firefox.md
Created November 28, 2019 06:18
Hide Native Tabs with Tree Style Tabs for Firefox
@PurpShell
PurpShell / monitor.js
Created May 13, 2024 14:48
Monitor Socket messages on 2.3000x and above
if (!window.decodeBackStanza) {
window.decodeBackStanza = require("WAWap").decodeStanza;
window.encodeBackStanza = require("WAWap").encodeStanza;
}
require("WAWap").decodeStanza = async (e, t) => {
const result = await window.decodeBackStanza(e, t);
@2minchul
2minchul / main.go
Created April 16, 2019 05:55
golang http client using specific network adapter
package main
import (
"context"
"fmt"
"io/ioutil"
"net"
"net/http"
)
@rponte
rponte / 1-CustomerCreatedEventSqsConsumer.java
Last active May 13, 2024 15:18
Spring Boot: Testing a @SqsListener with TestContainers and LocalStack
package br.com.zup.edu.app2.xxx.samples.aws.sqs;
import br.com.zup.edu.app2.xxx.samples.aws.sqs.model.Customer;
import br.com.zup.edu.app2.xxx.samples.aws.sqs.model.CustomerRepository;
import io.awspring.cloud.messaging.listener.SqsMessageDeletionPolicy;
import io.awspring.cloud.messaging.listener.annotation.SqsListener;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.messaging.handler.annotation.Header;